import axios from 'axios';

// 假设你的后端接口路径是 /api/aqi/listAqiAll
export const listAqiAll = async () => {
  try {
    const response = await axios.get('/api/aqi/listAqiAll'); // 请求路径
    return response.data;
  } catch (error) {
    console.error('Failed to fetch AQI data:', error);
    throw error; // 如果需要，可以在这里处理错误
  }
};